<%@ page language="java" pageEncoding="UTF-8" contentType="text/html;charset=utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@include file="/common/taglibs.jsp"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<%@ include file="/common/scripts.jsp"%>
<script type="text/javascript">
    $(function() {
        $("#queryBtn").click(function() {
            $("#theForm").submit();
        });
    });
</script>
</head>
<body>
  <div class="pageOuter">
    <div class="contentOuter">
      <!--search-->
      <div class="searchContainer">
        <form:form action="query" name="theForm" id="theForm" method="post" commandName="query">
          <table class="queryForm" style="width: auto;">
            <tr>
              <td><fmt:message key='system.bo.SysUser' /></td>
              <td><form:input path="username" size="15" cssStyle="width:100%;" /></td>
              <td><fmt:message key='system.bo.SysUser.email' /></td>
              <td><form:input path="email" size="15" cssStyle="width:100%;" /></td>
              <td><a href="javascript:void(0)" id="queryBtn" class="css_btn"><img class="button search"
                  src="<c:url value='/images/icon_transparent.png'/>" /> <fmt:message key='button.query' /></a></td>
            </tr>
          </table>
        </form:form>
      </div>
      <div class="pageTitle">
        <fmt:message key='menu.manage.user' />
      </div>
      <div class="buttonBox_R">
        <a href="<c:url value='add'/>" class="css_btn" style="float: right;"><img class="button add" src="<c:url value='/images/icon_transparent.png'/>" />
          <fmt:message key='button.add' /></a>
      </div>
      <c:if test='${sysUserList != null}'>
        <display:table name='sysUserList' id='sysUser' class='grid_list' requestURI='query'>
          <display:column titleKey='system.bo.SysUser.login' sortable='true' sortProperty='username'>
            <a href="<c:url value='edit?id=${sysUser.id }'/>"><c:out value='${sysUser.username}' /></a>
          </display:column>
          <display:column titleKey='system.bo.SysUser.name' sortable='true' sortProperty='displayName'>
            <c:out value='${sysUser.displayName}' />
          </display:column>
          <display:column titleKey='system.bo.SysUser.email' sortable='true' sortProperty='email'>
            <c:out value='${sysUser.email}' />
          </display:column>
          <display:column titleKey='system.bo.SysUser.enable' sortable='true' sortProperty='enable'>
            <c:if test="${sysUser.enable }">
              <fmt:message key='system.bo.SysUser.enable.true' />
            </c:if>
            <c:if test="${!sysUser.enable }">
              <fmt:message key='system.bo.SysUser.enable.false' />
            </c:if>
          </display:column>
          <%@include file="/common/displaytag.jsp"%>
        </display:table>
      </c:if>
    </div>
  </div>
</body>
</html>
